Remove this unneeded function, as it breaks state propagation.
authorMatthias Clasen <mclasen@redhat.com>
Fri, 5 Nov 2004 21:20:09 +0000 (21:20 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Fri, 5 Nov 2004 21:20:09 +0000 (21:20 +0000)
2004-11-05  Matthias Clasen  <mclasen@redhat.com>

* gtk/gtkcombobox.c (gtk_combo_box_menu_button_state_changed):
Remove this unneeded function, as it breaks state propagation.

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtkcombobox.c

index dc354e7a6a5a8bb2706399356fd4ee03a1eebd98..3701e6918cb1ad6ce1f14adedd5ba0d3585fb0ab 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2004-11-05  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkcombobox.c (gtk_combo_box_menu_button_state_changed):
+       Remove this unneeded function, as it breaks state propagation.
+
        * gtk/gtktearoffmenuitem.c (gtk_tearoff_menu_item_activate): 
        Queue the resize before setting the tearoff state, to 
        make sure the torn-off menu picks up the size increase due
index dc354e7a6a5a8bb2706399356fd4ee03a1eebd98..3701e6918cb1ad6ce1f14adedd5ba0d3585fb0ab 100644 (file)
@@ -1,5 +1,8 @@
 2004-11-05  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkcombobox.c (gtk_combo_box_menu_button_state_changed):
+       Remove this unneeded function, as it breaks state propagation.
+
        * gtk/gtktearoffmenuitem.c (gtk_tearoff_menu_item_activate): 
        Queue the resize before setting the tearoff state, to 
        make sure the torn-off menu picks up the size increase due
index dc354e7a6a5a8bb2706399356fd4ee03a1eebd98..3701e6918cb1ad6ce1f14adedd5ba0d3585fb0ab 100644 (file)
@@ -1,5 +1,8 @@
 2004-11-05  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkcombobox.c (gtk_combo_box_menu_button_state_changed):
+       Remove this unneeded function, as it breaks state propagation.
+
        * gtk/gtktearoffmenuitem.c (gtk_tearoff_menu_item_activate): 
        Queue the resize before setting the tearoff state, to 
        make sure the torn-off menu picks up the size increase due
index dc354e7a6a5a8bb2706399356fd4ee03a1eebd98..3701e6918cb1ad6ce1f14adedd5ba0d3585fb0ab 100644 (file)
@@ -1,5 +1,8 @@
 2004-11-05  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkcombobox.c (gtk_combo_box_menu_button_state_changed):
+       Remove this unneeded function, as it breaks state propagation.
+
        * gtk/gtktearoffmenuitem.c (gtk_tearoff_menu_item_activate): 
        Queue the resize before setting the tearoff state, to 
        make sure the torn-off menu picks up the size increase due
index 2b88dc09eaa107ca35159e6599471ca55bef3e38..e8b7da9fe78b592af60138ddea81833e930bb2dd 100644 (file)
@@ -225,9 +225,6 @@ static void     gtk_combo_box_style_set            (GtkWidget       *widget,
                                                     GtkStyle        *previous);
 static void     gtk_combo_box_button_toggled       (GtkWidget       *widget,
                                                     gpointer         data);
-static void     gtk_combo_box_button_state_changed (GtkWidget       *widget,
-                                                   GtkStateType     previous,
-                                                   gpointer         data);
 static void     gtk_combo_box_add                  (GtkContainer    *container,
                                                     GtkWidget       *widget);
 static void     gtk_combo_box_remove               (GtkContainer    *container,
@@ -781,23 +778,6 @@ gtk_combo_box_state_changed (GtkWidget    *widget,
   gtk_widget_queue_draw (widget);
 }
 
-static void
-gtk_combo_box_button_state_changed (GtkWidget    *widget,
-                                   GtkStateType  previous,
-                                   gpointer      data)
-{
-  GtkComboBox *combo_box = GTK_COMBO_BOX (data);
-
-  if (GTK_WIDGET_REALIZED (widget))
-    {
-      if (!combo_box->priv->tree_view && combo_box->priv->cell_view)
-       gtk_widget_set_state (combo_box->priv->cell_view, 
-                             GTK_WIDGET_STATE (widget));
-    }
-
-  gtk_widget_queue_draw (widget);
-}
-
 static void
 gtk_combo_box_check_appearance (GtkComboBox *combo_box)
 {
@@ -2321,9 +2301,6 @@ gtk_combo_box_menu_setup (GtkComboBox *combo_box,
   g_signal_connect (combo_box->priv->button, "button_press_event",
                     G_CALLBACK (gtk_combo_box_menu_button_press),
                     combo_box);
-  g_signal_connect (combo_box->priv->button, "state_changed",
-                   G_CALLBACK (gtk_combo_box_button_state_changed), 
-                   combo_box);
 
   /* create our funky menu */
   menu = gtk_menu_new ();
@@ -2474,10 +2451,6 @@ gtk_combo_box_menu_destroy (GtkComboBox *combo_box)
                                         G_SIGNAL_MATCH_DATA,
                                         0, 0, NULL,
                                         gtk_combo_box_menu_button_press, NULL);
-  g_signal_handlers_disconnect_matched (combo_box->priv->button,
-                                        G_SIGNAL_MATCH_DATA,
-                                        0, 0, NULL,
-                                        gtk_combo_box_button_state_changed, combo_box);
 
   /* unparent will remove our latest ref */
   gtk_widget_unparent (combo_box->priv->button);